package com.aichongbang.acb.mapper;

import com.aichongbang.acb.po.ItemOrder;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.ResultMap;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author acb
 * @since 2021-05-31
 */
@Repository("itemOrderMapper")
public interface ItemOrderMapper extends BaseMapper<ItemOrder> {

    @ResultMap("getAllOrders")
    List<ItemOrder> getAllOrders();

    @ResultMap("getOrderById")
    ItemOrder getOrderById(@Param("tId") Integer tID);

    @ResultMap("queryOrders")
    List<ItemOrder> queryOrders(ItemOrder itemOrder);

}
